Visit PANCROMA Website

See additional satellite image processing articles at www.PANCROMA.com menu selection 'White Papers'


Reading Data from ASCII Spectral Files

The United States Geological Survey (USGS) publishes several spectral libraries for a wide variety of mineral and organic materials. These spectra can be accessed and downloaded from the USGS Spectral Library website . An example of such a spectrum, for the mineral galena, is shown below.

[USGS Spectrum]


In its graphical form, reflectances can be picked off the graph and used for subsequent image processing, for example with the PANCROMA™ Spectral Analyzer. However extracting reflectances in this manner can be imprecise. Fortunately, the data is also offered in ASCII file format. In this form, the wavelength, reflectance, and standard deviation of the reflectance values are listed as shown in the excerpt below.

[USGS ASCII Data]


(Note that the asterisks mean missing data). Although ASCII format is not ideal for automated data extraction, in can usually be pulled off successfully if the data files are reasonably well behaved. Binary files are usually a better bet but these are not as widely available as the ASCII data.

PANCROMA™ can read reflectance data from such files an insert that data automatically into the Spectral Criteria form for subsequent analysis. In order to do so, first download the ASCII spectrum for the material you are interested in. Save it in the default .txt text file format. Next start PANCROMA™ and select 'File' | 'Open' and open the file. Next, select 'Spectral Analysis' | 'Read Spectrum from USGS ASCII File'. You must click the submenu selection for the type of data that you will be using for your subsequent analysis, for example Landsat ETM+. Note that there are two options for Landsat ETM+, depending on whether you intend to use the Thermal Infrared (TIR) band or not. If you decide to use the TIR band, you will have to input it manually into the Spectral Criteria form as the basic USGS spectral libraries do not include any TIR information.

When you click on the submenu, PANCROMA™ will search the file for the band wavelengths, and will extract the corresponding reflectances. It will place these reflectances into the Spectral Criteria form. They can then be conveniently used for either Manual or Euclidean Distance analysis.

Note that the band sensors are sensitive across a narrow range of wavelengths. PANCROMA™ will look up the reflectance that corresponds to the midpoint of the band. For example, the Landsat band1 reflectance will correspond to a wavelength of 0.4825 microns. The band reflectances for the mineral augite are shown tabulated below as reported to the text screen.

[Extracted Reflectances]


When you click 'Close Graphics Window and Reset' and then start a Landsat Euclidean Distance analysis, the reflectances will already be inserted into the reflectance value track bars, as shown in the image below.

[Extracted Reflectances]


Note that the band 6 (TIR) track bar is not set. This must be done manually.

NASA/JPL also publishes ASCII spectral libraries, found at the ASTER Spectral Library webpage . These are commonly called ASTER spectral data files, but they can be used with any data set. They are more comprehensive than the corresponding USGS libraries. They offer spectra for the visible, VNIR, SWIR and TIR spectral ranges. You must inspect the XStart and XStop limits carefully in order to determine the range of wavelengths included in a particular file. If the target wavelengths are not in the file you will obviously not get a match.

In order to read one of these ASCII files, select 'File' | 'Open' and open the file. Next, select 'Spectral Analysis' | 'Read Spectrum from ASTER ASCII File'. The submenus will specify your target wavelengths as described above for the USGS spectral files.

The JPL ASCII data are more complicated than the USGS data files. In addition to covering more spectral range, they are not as uniform in their formatting. For example, header data is not formatted with the same number of lines for each file. For some files the data starts at row position zero while for other files the data is indented with blank white spaces. The wavelength and reflectance columns are separated by blanks in some cases and a single tab character in others. In some files the data is listed in ascending numerical order, and in others the data is listed in descending order. These all need to be detected and handled. I believe that the PANCROMA™ ASCII readers are pretty robust and will handle any read failures kindly. However nothing is guaranteed reading ASCII data and I apologize in advance if you encounter occasional difficulties in reading the data.

USGS and ASTER spectral data are a valuable resource for multispectral analysis. Whether you access this data manually, or use the PANCROMA™ automated file read utilities, using this data will greatly enhance your analytical capabilities.



Web site and all contents © Copyright TERRAINMAP Earth Imaging LLC 2010, 2011, All rights reserved.